from flask import Blueprint

from libs.external_api import ExternalApi


bp = Blueprint("console", __name__, url_prefix="/console/api")
api = ExternalApi(bp)


# Import auth controllers
from .auth import activate, forgot_password, login, oauth


# Import tag controllers
from .tag import tags

from .auth import (
    activate,
    forgot_password,
    login,
    oauth,
)

# lobyliang
from .intent.funcs import RobFuncsApi
from .intent.fun_terms import RobFuncsTermsApi
from .robot import robot_api
from .robot.emoji_api import EmojiPackManageApi,EmojiManangeApi
from .robot.robot_agents import RobotAgentsApi
from .robot.character_api import CharacterManangeApi
from .robot.timbre_api import RobotTimbresApi
from .robot import fun_domain_api
from .robot import user_manage_api
from .robot import version_api
from .roles import roles,menus,users
from controllers.common.files import FileApi,FilePreviewURLApi
from controllers.mini_app.auth.role_info import GetUserRoutersApi,GetUserInfoApi
api.add_resource(FileApi, "/files/upload")
api.add_resource(FilePreviewURLApi, "/files/preview/url")
api.add_resource(GetUserRoutersApi, "/user/routers")
api.add_resource(GetUserInfoApi, "/user/info")

from controllers.online_mall import shop_manage
from controllers.online_mall import prod_manage
from controllers.online_mall import prod_prop
from controllers.online_mall import prod_tag_manage
from controllers.online_mall import prod_category
from controllers.online_mall import brands
from controllers.online_mall import user_addr
from controllers.online_mall import orders
from controllers.online_mall import pick_addr
from controllers.online_mall import transport